package com.jiyun.home.service.impl;

import com.jiyun.common.pojo.home.Merchant;
import com.jiyun.home.mapper.MerchantMapper;
import com.jiyun.home.service.MerchantService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@Service
@Transactional
public class MerchantServiceImpl implements MerchantService {
    @Autowired
    private MerchantMapper merchantMapper;
    /**
     * 添加商户信息
     *
     * 该方法用于将一个新的商户对象添加到数据源中
     * 它调用了merchantMapper的add方法来执行实际的数据持久化操作
     *
     * @param merchant 要添加的商户对象包含了商户的相关信息
     */
    @Override
    public void add(Merchant merchant) {
        merchantMapper.add(merchant);
    }
}
